package com.sxbbc.common.core.service.impl;

import org.springframework.stereotype.Service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.sxbbc.common.core.entity.jz.BOffline;
import com.sxbbc.common.core.enums.PayTypeEnums;
import com.sxbbc.common.core.mapper.jz.BOfflineMapper;
import com.sxbbc.common.core.service.IBOfflineService;
import com.sxbbc.common.core.utils.BasePage;

/**
 * <p>
 * 线下买单记录 服务实现类
 * </p>
 *
 * @author xiaoky
 * @since 2019-05-28
 */
@Service
public class BOfflineServiceImpl extends ServiceImpl<BOfflineMapper, BOffline> implements IBOfflineService {

	@Override
	public IPage<BOffline> queryOfflineList(BasePage<BOffline> page, BOffline bOffline) {
		baseMapper.queryOfflineList(page, bOffline);
		for (BOffline b:page.getRecords()) {
			b.setPayTypeName(PayTypeEnums.getName(b.getPayType()));
		}
		return page;
	}

}
